<%@page language="java" contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/common/taglib.jsp"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>${page.pageName}</title>
<%@include file="/common/public.jsp"%>
<link rel="stylesheet" type="text/css" href="${ctx}/css/main.css">
<link rel="stylesheet" type="text/css" href="${ctx}/css/query.css">
<script type="text/javascript">
window.Action = {};
Action.qry = function(){
	jQuery("form:first").submit();
};
jQuery( function(){
	if( "${page.autoQuery}" == "1" ){
		Action.qry();
	}
});
jQuery( function(){
	jQuery(".qry_down").toggle( function(){
		jQuery(".xtable .qry_hide").show();
		jQuery(this).html("<a  href='#'>隐藏更多查询条件</a>");
		jQuery(this).removeClass("qry_down");
		jQuery(this).addClass("qry_up");
	},function(){
		jQuery(".xtable .qry_hide").hide();
		jQuery(this).html("<a  href='#'>显示更多查询条件</a>");
		jQuery(this).addClass("qry_down");
		jQuery(this).removeClass("qry_up");
})});
</script>
<!-- 自定义脚本 start-->
${page.mainScript}
<!-- 自定义脚本 end-->
</head>
<body>
<c:choose>
<c:when test="${page.pageUrl == '' || page.pageUrl == null}">
  <c:set value="${ctx}/query/list.do" var="action"/>
</c:when>
<c:otherwise>
  <c:set value="${ctx}/${page.pageUrl}" var="action"/>
</c:otherwise>
</c:choose>
<form name="QryForm" action="${action}" method="post"  target="ListWindow" style="margin:0px"/>
<input type="hidden" name="pageId" value="${page.pageId}" />
<!-- URL请求传递过来的参数 start -->
${parameters}
<!-- URL请求传递过来的参数 end -->
<table class="xtable">
	<tbody id="QryArea">
		<tr>
			<td>
				<table class="qry_bg">
					<tr>
						<td colspan="2">
							<page:query moduleId="${page.moduleId}"/>
						</td>
					</tr>
					<tr class="qry_hr">
						<td colspan="2"></td>
					</tr>
					<tr class="qry_more">
						<td><span class="qry_down" id="MoreQueryButton"><a href="#">显示更多查询条件</a></span></td>
						<td class="qry_button">
						${page.button}
						<input name="QryButton" type="button" class="btn_orange_b2" value="查 询" onClick="Action.qry()"/>
						</td>
					</tr>
				</table>
			</td>
		</tr>
	</tbody>
	<script type="text/javascript">
		jQuery( function(){
			if( "${isQry}" == "false")
				jQuery("#QryArea").hide();
		});
	</script>
	<tr>
		<td class="qry_frame">
			<iframe src="${ctx}/page/query/list.jsp" name="ListWindow"
				          width="100%" height="100%" scrolling="no" frameborder="0">
			</iframe>
		</td>
	</tr>
</table>
</form>
<%@include file="/common/footer.jsp"%>
</body>
</html>